home *** CD-ROM | disk | FTP | other *** search
/ Language/OS - Multiplatform Resource Library / LANGUAGE OS.iso / pcr / pcr4_4.lha / DIST / debugnub / INCLUDE / xr / OLDCirioNubInstall.h < prev    next >
C/C++ Source or Header  |  1989-11-02  |  3KB  |  106 lines

  1. /* begincopyright
  2.   Copyright (c) 1988 Xerox Corporation. All rights reserved.
  3.   Use and copying of this software and preparation of derivative works based
  4.   upon this software are permitted. Any distribution of this software or
  5.   derivative works must comply with all applicable United States export
  6.   control laws. This software is made available AS IS, and Xerox Corporation
  7.   makes no warranty about the software, its performance or its conformity to
  8.   any specification. Any person obtaining a copy of this software is requested
  9.   to send their name and post office or electronic mail address to:
  10.     PCR Coordinator
  11.     Xerox PARC
  12.     3333 Coyote Hill Rd.
  13.     Palo Alto, CA 94304
  14.   endcopyright */
  15.  
  16. /*
  17.  * CirioNubInstall.h
  18.  *
  19.  * Demers, November 2, 1989 10:11:22 am PST
  20.  *
  21.  * Primitives used to install CirioNub.
  22.  */
  23.  
  24. #ifndef _CIRIO_NUB_INSTALL_
  25. #define _CIRIO_NUB_INSTALL_
  26.  
  27. #include "xr/Threads.h"
  28. #include "xr/CirioNubProtocol.h"
  29.  
  30.  
  31. /*
  32.  * types
  33.  */
  34.  
  35. typedef char * CirioNubHandle;
  36. /*
  37.     (opaque) handle for CirioNub server
  38. */
  39.  
  40. typedef CirioNubRetCode
  41. (*CirioNubProc)(/* int argc, unsigned *args */);
  42. /*
  43.     Proc invoked from other side.
  44.     Calling and called (this) procedure must agree on number and type
  45.         of args.
  46.     Return results by calling the marshalling procedures (below)
  47.         and returning the appropriate CirioNubRetCode value.
  48. */
  49.  
  50. typedef void
  51. (*CirioNubInitProc)(/* void * clientData */);
  52. /*
  53.     Initialization proc for CirioNub.
  54.     Called on slave IOP before creating listener.
  55. */
  56.  
  57.  
  58. /*
  59.  * procs
  60.  */
  61.  
  62. extern CirioNubHandle
  63. CirioNubCreateHandle(/* int maxProcs, int callBufBytes */);
  64. /*
  65.     Create a CirioNub handle and return it.
  66.     Parameters are max number of procs that can be registered with this handle
  67.         and max number of bytes of arguments that can be processed.
  68.     Reserve a slave IOP for the handle to execute in.
  69.     Return NIL on failure.
  70. */
  71.  
  72.  
  73. extern int
  74. CirioNubRegisterCProc(/* CirioNubHandle h, int procID, CirioNubProc proc */);
  75. /*
  76.     Register a C procedure with given procID.
  77.     Handle h must not yet have been installed.
  78.     Return 0 on success, (-1) on failure.
  79. */
  80.  
  81.  
  82. extern int
  83. CirioNubRegisterMProc(/* CirioNubHandle h, int procID, XR_MesaProc mp */);
  84. /*
  85.     Analogous to CirioNubRegisterCProc, but registers a Mesa proc.
  86. */
  87.  
  88.  
  89. extern int
  90. CirioNubInstall(/*
  91.     CirioNubHandle h,
  92.     unsigned listenerPort,
  93.     CirioNubInitProc initProc,
  94.     void *clientData
  95. */);
  96. /*
  97.     Install debug nub with procedures registered with handle h
  98.         listening at given TCP port.
  99.     If port is 0, well-known default port is used.
  100.     The initProc(clientData) is called in the slave IOP before the listener
  101.         is created.
  102. */
  103.  
  104.  
  105. #endif /* _CIRIO_NUB_INSTALL_ */
  106.